export function defReducer(state = {}, action) {
  switch (action.type) {
    case "decrement":
      return { ...state, num: state.num - 1 };
    case "increment":
      return { ...state, num: state.num + 1 };
    case "success_data":
      return { ...state, obj: action };
    default:
      break;
  }
  return Object.assign({}, state, action);
  // return state;
}
